import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { Code404Component} from './code404/code404.component';
import { ProductComponent} from './product/product.component';

const routes: Routes = [
  {path: 'design', loadChildren: './design/design.module#DesignModule'},
  {path: 'test', loadChildren: './test/test.module#TestModule'},
  {path: 'front', loadChildren: './front/front.module#FrontModule'},
  {path: 'back', loadChildren: './back/back.module#BackModule'},
  {path: 'product', component: ProductComponent},
  {path: '**', component: Code404Component}
];

@NgModule({
  imports: [RouterModule.forRoot(routes)],
  exports: [RouterModule]
})
export class AppRoutingModule { }
